GenerativeComponents Help

Color and Appearance

Many GenerativeComponents nodes contain a number of color and appearance properties that can be changed by using the MicroStation Attributes toolbox. Some of the appearance properties include line weight, line style, level name, and color.

When creating a new node, the active attribute settings are applied to the new node. For example, if the active color is red (color #3), all new geometric nodes (lines, surfaces, solids, polygons, etc.) will be red. However, GenerativeComponents does not record the active color settings when the node is created. As a result, when the transaction step is turned off and the active color settings are changed, replaying the transaction will create the node with the new color settings. However, most of the active color settings can be hard-coded into a node by manually writing these settings into the node's properties within the transaction history file.

The following examples show a line that has a number of settings added manually:

transaction 1 modelChange 'Add coordinateSystem1'
{
    node User.Objects.coordinateSystem1 Bentley.GC.NodeTypes.CoordinateSystem
    {
        Technique                 = 'AtModelOrigin';
        GraphLocation             = <auto> {40.0, 40.0};
    }
}

transaction 2 modelChange 'Change coordinateSystem1'
{
    node User.Objects.coordinateSystem1 Bentley.GC.NodeTypes.CoordinateSystem
    {
        GraphLocation             = {15.52, 50.08, 174.0, 0.0};
    }
}

transaction 3 modelChange 'Change coordinateSystem1'
{
    node User.Objects.coordinateSystem1 Bentley.GC.NodeTypes.CoordinateSystem
    {
        Technique                 = 'AtModelOrigin';
        DGNModelName              = '3D Metric Design';
    }
}

transaction 4 modelChange 'Add point01'
{
    node User.Objects.point01 Bentley.GC.NodeTypes.Point
    {
        Technique                 = 'ByCartesianCoordinates';
        XTranslation              = <free> 0.0;
        YTranslation              = <free> 0.0;
        ZTranslation              = <free> 0.0;
        GraphLocation             = <auto> {289.52, 50.08};
    }
}

transaction 5 modelChange 'Add point02'
{
    node User.Objects.point02 Bentley.GC.NodeTypes.Point
    {
        Technique                 = 'ByCartesianCoordinates';
        XTranslation              = <free> 0.0;
        YTranslation              = <free> 0.0;
        ZTranslation              = <free> 0.0;
        GraphLocation             = <auto> {289.52, 245.95};
    }
}

transaction 6 modelChange 'Change point02'
{
    node User.Objects.point02 Bentley.GC.NodeTypes.Point
    {
        Technique                 = 'ByCartesianCoordinates';
        XTranslation              = 10;
    }
}

transaction 7 modelChange 'Change point02'
{
    node User.Objects.point02 Bentley.GC.NodeTypes.Point
    {
        Technique                 = 'ByCartesianCoordinates';
        ZTranslation              = -9;
    }
}

transaction 8 modelChange 'Add line01'
{
    node User.Objects.line01 Bentley.GC.NodeTypes.Line
    {
        EndPoint                  = point01;
        StartPoint                = point02;
        Color                     = 3;
        LevelName                 = "Default";
        LineWeight                = 2;
   }
}
Tip: Currently, GenerativeComponents does not support manually inputting transparency settings. However, when the transparency settings are changed in the Attributes toolbox, all nodes created will display the active transparency settings. One way around this is by defining a MicroStation level that has transparency. Details about color control are in the Color section.